package game.targets.device;

import game.targets.Constants;
import game.targets.entity.Entity;

import com.badlogic.gdx.Gdx;
import com.badlogic.gdx.graphics.g2d.SpriteBatch;
import com.badlogic.gdx.scenes.scene2d.Stage;

//put Android specific code in these functions
public class DeviceAndroid implements Device, Constants {
	private Stage stage;
	private SpriteBatch uiBatch;
	private boolean paused;

	public DeviceAndroid() {
		stage = new Stage(Gdx.graphics.getWidth(), Gdx.graphics.getHeight(), true, uiBatch);
	}

	@Override
	public void getInput(Entity block, float delta) {
	}

	@Override
	public void initControls() {
		/*paused = false;
		uiBatch = new SpriteBatch();
		
		// Create a Stage and add TouchPad
		
		stage.addActor(buttonPause);
		stage.addActor(Locator.getPad());
		Locator.getInputMultiplexer().addProcessor(stage);*/
	}

	@Override
	public void updateDevice(float delta) {
		if (paused) {
			//Locator.getMessageService().displayMessage("Paused", Gdx.graphics.getWidth() / 2.2f, Gdx.graphics.getHeight() / 2f);
		}
		stage.act(delta);
	}

	@Override
	public void renderDevice() {
		stage.draw();
	}

}
